package com.sl.au.service;

import java.util.List;
import java.util.Map;

import com.sl.au.entity.Chance;
import com.sl.au.entity.ChanceDelivery;
import com.sl.au.entity.ChanceDeliveryTemp;
import com.sl.au.entity.User;
import com.sl.au.repository.ChanceDeliveryRepository;
import com.sl.au.repository.ChanceDeliveryTempRepository;

public interface ChanceDeliveryService  extends BaseService{
	ChanceDeliveryRepository getRepository();
	
	ChanceDeliveryTempRepository getDeliveryTempRepository();
	/**
	 * 获取处长页面分页数据
	 * @param start
	 * @param length
	 * @param key
	 * @param orderName
	 * @param dir
	 * @return
	 */
	List<Chance>   getPage(int start, int length,Map<String,String> condition,int targetType,String orderName ,String dir);
	List<Chance>   getPage(int start, int length,Map<String,String> condition,String orderName ,String dir);
	/**
	 * 获取销售经理页面分页数据
	 * @param start
	 * @param length
	 * @param key
	 * @param orderName
	 * @param dir
	 * @return
	 */
	List<ChanceDelivery>   getManagerPage(int start, int length,Map<String,String> condition,int targetType,String orderName ,String dir);
	List<ChanceDelivery>   getManagerPage(int start, int length,Map<String,String> condition,String orderName ,String dir);
	/**
	 * 获取信息片区分配弹窗数据
	 * @param start
	 * @param length
	 * @param key
	 * @param orderName
	 * @param dir
	 * @return
	 */
	List<ChanceDelivery>   getModulePage(int start, int length,Map<String,Object> condition,String orderName ,String dir);
	/**
	 * 获取信息发起协作弹窗数据
	 * @param start
	 * @param length
	 * @param key
	 * @param orderName
	 * @param dir
	 * @return
	 */
	List<ChanceDeliveryTemp>   getModulePageCoop(int start, int length,String chanceId,String orderName ,String dir);
	
	/**关闭一个信息
	 * @param chanceId
	 */
	void closeChance(User user,String chanceId,String reason,String contractCode,String result);
}
